import { defineStore } from 'pinia';
export interface EmailState {
  COMMON: number;
  LOGIN: number;
  REGISTER: number;
  RESETPWD: number;
}
export interface SmsState {
  OP_REG: number;
  OP_LOGIN: number;
}
export interface CaptchaState {
  sms: SmsState
  email: EmailState
}

export const useCaptchaStore = defineStore({
  id: 'captcha',
  state: (): CaptchaState => ({
    email: {
      // 公共 20000
      COMMON: 0,
      // 登录 10001
      LOGIN: 0,
      // 注册 10000
      REGISTER: 0,
      // 重置登录密码 10002
      RESETPWD: 0,
    },
    sms: {
      // 注册
      OP_REG: 0,
      // 登录
      OP_LOGIN: 0,
    }
  }),
  actions: {
  },
});
